<html>
<style type="text/css">
		body {
			font-size : 100%;
			padding: 40px;
			margin: 0 0 30px 0;
		}
		body, td, th {
			font-family : lucida grande, arial, helvetica, sans-serif;
			font-size : 10pt;
		}
		h2,h3,h4,h5 {
			color: #335588;
			border-bottom : 1px #ccc dotted;
		}
	</style>
<body>
<div id="pageContainer">
<h1>Example Plugin Readme</h1>
<p>A kind of smorgasbord, this plugin includes several simple examples designed to show how plugins and macros work.</p>
<h2>What's Included</h2>
<h3>What the Samples Do</h3>
<p>The samples here include:</p>
<ul>
	<li>An {author} macro that displays the name of the user currently logged in.
		<p>To test: Create a wiki document, add {author} to the document, then publish the document.</p>
	</li>
	<li>A "Hello World" tab in the admin console.
		<p>To test: Display the admin console, then click the Hello World tab. You'll get a new "Hello World" page.</p>
	</li>
	<li>An "Example Test" menu in the user bar.
		<p>To test: Display the Clearspace UI, click the Example Test menu, then click the Example command. You'll get a new page displaying results from actions included in this plugin.</p>
	</li>
	<li>An "Example Plugin" link in the community Actions box.
		<p>To test: Display the Clearspace UI, navigate to a sub-community, then click the link. You'll get a new page displaying results from actions included in this plugin.</p>
	</li>
	<li>An "EchoService" web service that returns text submitted to it.
		<p>To test: Write a web service client that calls the echo operation with some string. The service returns that string, prepended with the name of the user who sent it.</p>
	</li>
	<li>A "Hello World" widget that displays a simple greeting.
		<p>To test: Display the Clearspace UI, navigate to a sub-community, then click the customize link on the Overview tab. From the list of widgets, drag the Hello World Widget. Set its properties, then publish the Overview to see how the widget's displayed to users.</p>
	</li>
</ul>
<h3>Java Source</h3>
<ul>
	<li>ExamplePlugin.java</li>
	<li>ExampleAdminAction.java</li>
	<li>ExampleCommunityAction.java</li>
	<li>ExampleProfileAction.java</li>
	<li>IncludedPageAction.java</li>
	<li>AuthorsNameMacro.java</li>
	<li>EchoService.java</li>
	<li>HelloWorldWidget.java</li>
</ul>
<h3>Resources</h3>
<ul>
	<li>example-community.ftl</li>
	<li>example-profile.ftl</li>
	<li>examples.css</li>
	<li>example.ftl</li>
	<li>hello-world.ftl</li>
	<li>helloworld.ftl</li>
	<li>included-page.ftl</li>
</ul>
<h3>Scripts</h3>
<ul>
	<li>AuthorsNameMacro.groovy</li>
	<li>AuthorsNameMacro.py</li>
	<li>AuthorsNameMacro.rb</li>
	<li>BoldItalicMacro.groovy</li>
	<li>DisplayDateMacro.rb</li>
</ul>

<h2>Building and Deploying the Code</h2>
<p>The Ant build.xml file at the root of the plugin includes a build.plugins target you can use to compile the code and package it into a JAR file. There's also a deploy.plugins target that copies the JAR into the &lt;jiveHome&gt;/plugins directory that accompanies your Clearspace distribution. Paths into your test Clearspace distribution assume that this plugin project is in the standalone Clearspace distribution at: &lt;root&gt;/plugins/plugins/helloworld. Be sure to update the targets if you're testing another way, such as with the Clearspace WAR distribution.</p>
<p>Be sure to read the notes below about dependencies. The JAR files you'll need are included as part of Clearspace.</p>
<p>If you'd rather deploy the plugin manually, you can do that in one of two ways:</p>
<ul>
    <li>Just copy the plugin JAR file into the &lt;jiveHome&gt;/plugins directory. Your running Clearspace instance will deploy it automatically.</li>
    <li>Open the admin console and navigate to System > Plugins, then click Add Plugin and browse for your plugin JAR file.</li>
</ul>
<h2>Dependencies</h2>
<p>In addition to requiring Java 1.5, this code requires a few of the libraries you'll find in the WEB-INF/lib directory of your Clearspace installation, listed below. <ul>
    <li>clearspace-&lt;version&gt;.jar</li>
    <li>freemarker.jar</li>
    <li>rife-continuations.jar</li>
    <li>webwork.jar</li>
    <li>xfire-jsr181.jar</li>
    <li>xwork.jar</li>
</ul>
</p>
</div>
</body>
</html>
